﻿using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using ExpertMIS.Brokers;

namespace ExpertMIS.Admin.UserControl
{
    public partial class DefaultForm : System.Web.UI.UserControl
    {
        private ADMUserBroker userBroker = new ADMUserBroker();
        private QuestionBroker questionBroker = new QuestionBroker();
        private TroubleBroker tblBroker = new TroubleBroker();
        private ExpertBroker epBroker = new ExpertBroker();

        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack) 
            {
                // 设置待审核用户信息总条数
                lblUser.Text = userBroker.GetUnPassedUserCount().ToString() + "条";
                // 设置待审核问题信息总条数
                lblQuestions.Text = questionBroker.GetUnPassedQuestionsCount().ToString() + "条";
                // 设置待处理困难信息总条数
                lblTrouble.Text = tblBroker.GetUnPassedTroublesCount().ToString() + "条";

                lblRegisterUser.Text = userBroker.GetRegisterUserCount().ToString() + "人";
                lblExpert.Text = userBroker.GetExpertCount().ToString() + "人";
            }
        }
    }
}